package com.example.webmodule.controller;

import com.example.webmodule.ratelimiter.annotation.RateLimiter;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @ClassName EY-LimitController
 * @Description com.example.webmodule.controller
 * @Author menyj
 * @Date 2025/4/17
 **/
@RestController
@RequestMapping("/sms")
public class LimitController {

    @RateLimiter(key = "#phonenumber", time = 60, count = 1)
    @GetMapping("/code")
    public String smsCaptcha(String phonenumber) {
        return "123";
    }
}
